Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix: Register named parameters earlier #301

Merged
merged 1 commit into from
Nov 1, 2023
Merged

Conversation

glx22
Copy link
Contributor

@glx22 glx22 commented Aug 4, 2023

Named parameters are registered during pre_process step, which can be too late.
Move the registration to register_names step.

@frosch123
Copy link
Member

@glx22 Is it possible to add a simple regression test case for this?

@glx22
Copy link
Contributor Author

glx22 commented Nov 1, 2023

I'm not even sure it's possible to actually see the effect of this PR without more changes.
If I use 5a5b481 (and a named param for house id in 030) without this PR I get "unrecognized identifier", with the PR it becomes "Expected a compile-time integer constant"

@glx22 glx22 merged commit 2491279 into OpenTTD:master Nov 1, 2023
21 checks passed
@glx22 glx22 deleted the named_param branch November 1, 2023 20:14
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants